package com.aat.dxfy.jdbc.datasource;

import java.sql.Connection;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.sql.Statement;

public class TestDAO {

	private final static String sql = "SELECT nickname FROM base_user u WHERE u.account='admin'";

	public static void query(Connection conn) {
		try {
			Statement st = conn.createStatement();
			ResultSet result = st.executeQuery(sql);
			while (result.next()) {
				result.getString("nickname");
			}
			
		} catch (SQLException e) {
			e.printStackTrace();
		}
	}
}